import Vue from 'vue'
import { USER_INFO } from "@/store/mutation-types"
const getters = {
  token: state => state.user.token,
  avatar: state => {state.user.avatar = Vue.ls.get(USER_INFO).avatar; return state.user.avatar},
  username: state => {state.user.username = Vue.ls.get(USER_INFO).username; return state.user.username},
  nickname: state => {state.user.realName = Vue.ls.get(USER_INFO).realName; return state.user.realName},
  userInfo: state => {state.user.info = Vue.ls.get(USER_INFO); return state.user.info},
  permissionList: state => state.user.permissionList,
  addRouters: state => state.permission.addRouters,
}
export default getters
